infoGo to Tips Page
messageTech Support
  • Prepare for InterviewPrepare for Interview
  • AcknowledgementsAcknowledgements
  • Test hardwareTest hardware
  • What to ExpectWhat to Expect
  • Start InterviewStart Interview
  • Video QuestionVideo Question
  • Video QuestionVideo Question
  • Video QuestionVideo Question
  • Algorithm QuestionAlgorithm Question
  • SQL QuestionSQL Question
  • Data Science QuestionData Science Question
  • AvailabilityAvailability
  • Preview & SubmitPreview & Submit
  • Finish InterviewFinish Interview
Powered by

Question 5/6

"Investor Performance"

Your solution will be scored against expected output.


The table, INVESTOR_TABLE_2019, contains performance data for the investors working at an investment company in 2019.


Write a query which will return the INVESTOR_IDs of the investors whose investment accounts experienced a greater than average percentage return in 2019 amongst all investors. Order your results by INVESTOR_ID in ascending order.




In the returned query be sure to use the column names used in the sample output given below.


Data:

Table Name : INVESTOR_TABLE_2019


Sample Input:



Sample Output:


Explanation:

The percentage returns for investors 196208, 196202, 196212, and 196298 are 0.10, -0.70, 1.00, and 0.20 respectively, which means the average percent return amongst these investors is 0.15.


Therefore, the sample output consists of two rows containing the investor ids of the two investors who attained higher than average percentage returns.



Query Results
Run a query to see results
Database Schema
INVESTOR_TABLE_201950 rows
INVESTOR_IDINT
OFFICE_IDINT
INITIAL_ACCOUNT_VALUEDOUBLE
FINAL_ACCOUNT_VALUEDOUBLE
3
The screen capture will appear in this box.